home *** CD-ROM | disk | FTP | other *** search
/ IRIX 6.5 Complementary Applications 2004 May / SGI IRIX 6.5 Complementary Applications 2004 May.iso / dist / OpenOffice.idb / usr / OpenOffice / program / jvmsetup.z / jvmsetup
Encoding:
Text File  |  2003-07-29  |  3.9 KB  |  129 lines

  1. #!/bin/sh
  2. #*************************************************************************
  3. #
  4. #   $RCSfile: jvmsetup.sh,v $
  5. #
  6. #   $Revision: 1.3.18.1 $
  7. #
  8. #   last change: $Author: mrauch $ $Date: 2002/04/06 10:22:21 $
  9. #
  10. #   The Contents of this file are made available subject to the terms of
  11. #   either of the following licenses
  12. #
  13. #          - GNU Lesser General Public License Version 2.1
  14. #          - Sun Industry Standards Source License Version 1.1
  15. #
  16. #   Sun Microsystems Inc., October, 2000
  17. #
  18. #   GNU Lesser General Public License Version 2.1
  19. #   =============================================
  20. #   Copyright 2000 by Sun Microsystems, Inc.
  21. #   901 San Antonio Road, Palo Alto, CA 94303, USA
  22. #
  23. #   This library is free software; you can redistribute it and/or
  24. #   modify it under the terms of the GNU Lesser General Public
  25. #   License version 2.1, as published by the Free Software Foundation.
  26. #
  27. #   This library is distributed in the hope that it will be useful,
  28. #   but WITHOUT ANY WARRANTY; without even the implied warranty of
  29. #   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
  30. #   Lesser General Public License for more details.
  31. #
  32. #   You should have received a copy of the GNU Lesser General Public
  33. #   License along with this library; if not, write to the Free Software
  34. #   Foundation, Inc., 59 Temple Place, Suite 330, Boston,
  35. #   MA  02111-1307  USA
  36. #
  37. #
  38. #   Sun Industry Standards Source License Version 1.1
  39. #   =================================================
  40. #   The contents of this file are subject to the Sun Industry Standards
  41. #   Source License Version 1.1 (the "License"); You may not use this file
  42. #   except in compliance with the License. You may obtain a copy of the
  43. #   License at http://www.openoffice.org/license.html.
  44. #
  45. #   Software provided under this License is provided on an "AS IS" basis,
  46. #   WITHOUT WARRUNTY OF ANY KIND, EITHER EXPRESS OR IMPLIED, INCLUDING,
  47. #   WITHOUT LIMITATION, WARRUNTIES THAT THE SOFTWARE IS FREE OF DEFECTS,
  48. #   MERCHANTABLE, FIT FOR A PARTICULAR PURPOSE, OR NON-INFRINGING.
  49. #   See the License for the specific provisions governing your rights and
  50. #   obligations concerning the Software.
  51. #
  52. #   The Initial Developer of the Original Code is: Sun Microsystems, Inc..
  53. #
  54. #   Copyright: 2000 by Sun Microsystems, Inc.
  55. #
  56. #   All Rights Reserved.
  57. #
  58. #   Contributor(s): _______________________________________
  59. #
  60. #
  61. #
  62. #*************************************************************************
  63.  
  64. # resolve installation directory
  65. sd_platform=`uname -s`
  66. case $sd_platform in
  67.     SCO_SV) test=/bin/test     ;;
  68.     NetBSD) test=/bin/test     ;;
  69.     *)      test=/usr/bin/test ;;
  70. esac
  71.  
  72. sd_cwd="`pwd`"
  73. if $test -L "$0" ; then
  74.     sd_basename=`basename "$0"`
  75.     sd_script=`ls -l $0 | sed "s/.*${sd_basename} -> //g"`
  76. else
  77.     sd_script="$0"
  78. fi
  79.  
  80. cd "`dirname "$sd_script"`/.."
  81. sd_binary=`basename "$sd_script"`".bin"
  82. sd_inst="`pwd`"
  83.  
  84. # change back directory
  85. cd "$sd_cwd"
  86.  
  87. sd_fonts=$sd_inst/fonts
  88.  
  89. # set search path for shared libraries
  90. case $sd_platform in
  91.   SunOS)
  92.     sd_arch=`uname -p`
  93.     LD_LIBRARY_PATH=$sd_inst/program/local:$sd_inst/program/service:$sd_inst/program:/usr/openwin/lib:/usr/dt/lib:$LD_LIBRARY_PATH
  94.     export LD_LIBRARY_PATH
  95.     ;;
  96.  
  97.   AIX)
  98.     LIBPATH=$sd_inst/program:$LIBPATH
  99.     export LIBPATH
  100.     ;;
  101.  
  102.   HP-UX)
  103.     SHLIB_PATH=$sd_inst/program/local:$sd_inst/program:/usr/openwin/lib:$SHLIB_PATH
  104.     export SHLIB_PATH
  105.     ;;
  106.  
  107.   IRIX)
  108.     LD_LIBRARYN32_PATH=:$sd_inst/program/local:$sd_inst/program:$LD_LIBRARYN32_PATH
  109.     export LD_LIBRARYN32_PATH
  110.     ;;
  111.  
  112.   *)
  113.     LD_LIBRARY_PATH=$sd_inst/program/local:$sd_inst/program:$LD_LIBRARY_PATH
  114.     export LD_LIBRARY_PATH
  115.     ;;
  116. esac
  117.  
  118. # misc. environment variables
  119. SAL_FONTPATH=$sd_fonts/type1:$sd_fonts/75dpi
  120.  
  121. unset XENVIRONMENT
  122.  
  123. export SAL_FONTPATH
  124.  
  125. # execute soffice binary
  126. # there is a bug in solaris sh that prevents the use of "$@"
  127. # because it cannot cope with spaces in directory names
  128. exec "$sd_inst/program/$sd_binary" "$1" "$2" "$3" "$4" "$5" "$6" "$7" "$8" "$9"
  129.